_Pragma("once");

#include "ScrollEditablePage.h"
#include "NumberEditor.h"
#include "common.h"
#include "LoopControlInfo.h"
#include "IButtonListener.h"


class TimedLoopCommandManager;

class TimedComandConfigPage : public ScrollEditablePage, private IButtonListener {
   static const StringVectorPtr fourOrFive;

public:
    using super =  ScrollEditablePage;

    TimedComandConfigPage(const int pageNum);

    /** Default destructor */
    virtual ~TimedComandConfigPage();



    void paint() override;
    void initEditors() override;
    void setValue() override;
    void saveValue() override;
    void beforeDisplay() override;

//    void doSetPageNo(const int pageNo) override;

protected:
    int onClick(const uint16_t id, Button* const pbutton) override;

    TimedLoopCommandManager&  mtimedLoopCommandManager;

    BasicEditorVector msecondEditors;

    std::tm mbeginTime;
    std::tm mendTime;
    LoopControlInfoPtr mploopControlInfo;

};
